-- GENERATED SPELL FOR [Wildspawn Hellcaller] --


function spell0_11457(pUnit, Event) --@Fireball,n/a--
pUnit:FullCastSpellOnTarget(15228,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11457', 3000, 1)
end

function spell1_11457(pUnit, Event) --@Rain of Fire,n/a--
pUnit:FullCastSpellOnTarget(20754,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_11457', 9000, 1)
end

function Sorts_11457(pUnit, Event)
local choix_sorts_11457 = math.random(0, 1)
if choix_sorts_11457 == 0 then
pUnit:RegisterEvent('spell0_11457', 1, 1)
end
if choix_sorts_11457 == 1 then
pUnit:RegisterEvent('spell1_11457', 1, 1)
end
end

function mob11457_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_11457', math.random(1500, 3000), 1)
end

function mob11457_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11457_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob11457_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(11457, 1, 'mob11457_Action')
RegisterUnitEvent(11457, 2, 'mob11457_Leave')
RegisterUnitEvent(11457, 3, 'mob11457_Kill')
RegisterUnitEvent(11457, 4, 'mob11457_Die')
